package com.example.microservice.dto.server.map;

import com.example.microservice.common.base.Dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.util.Objects;

/**
 * @Author: caohuijie
 * @Date: 创建日期 2018/11/7
 * @Modified By:
 * @Description: 地图质心dto
 */
@ApiModel(value = "MapCenterPoint",description = "地图质心")
public class MapCenterPoint implements Dto {

    private static final long serialVersionUID = -5767538561879590189L;

    @ApiModelProperty(value = "唯一标识符",example = "151578668489")
    private String uniqueId;


    @ApiModelProperty(value = "经度",example = "116.42765814663355")
    private String coordx;

    @ApiModelProperty(value = "纬度",example = "39.89735517775165")
    private String coordy;


    public String getCoordx() {
        return coordx;
    }

    public void setCoordx(String coordx) {
        this.coordx = coordx;
    }

    public String getCoordy() {
        return coordy;
    }

    public void setCoordy(String coordy) {
        this.coordy = coordy;
    }


    public String getUniqueId() {
        return uniqueId;
    }

    public void setUniqueId(String uniqueId) {
        this.uniqueId = uniqueId;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof MapCenterPoint)) return false;
        MapCenterPoint that = (MapCenterPoint) o;
        return Objects.equals(uniqueId, that.uniqueId) &&
                Objects.equals(coordx, that.coordx) &&
                Objects.equals(coordy, that.coordy);
    }

    @Override
    public int hashCode() {

        return Objects.hash(uniqueId, coordx, coordy);
    }
}
